﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;

namespace Nova_BLL
{
    public class TSysoption
    {
        DataSet ds = null;
        string strColor = "";
        Nova_DAL.TSysoption Nova_DAL_TSysoption = new Nova_DAL.TSysoption();

        ///<summary>
        ///获取货位存储类型信息
        ///TSysoption表的存储类型的值是104,这个值是固定值
        ///</summary>
        ///<param name="sQL">SQL</param>
        ///<returns>返回dataset</returnss>
        ///Writer：[王成友]
        ///Create Date： [2010-7-8]
        ///</summary>
        public DataSet DataListTSysoption(int iDisOne)
        {
            try
            {
                ds = Nova_DAL_TSysoption.DataListTSysoption(iDisOne);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());
            }
            return ds;
        }

        /// <summary>
        /// 获取尺寸 表示名称、数值
        /// </summary>
        /// <param name="iDisOne"></param>
        /// <returns></returns>
        public DataSet DataListTSysoptionSize(int iDisOne)
        {
            try
            {
                ds = Nova_DAL_TSysoption.DataListTSysoptionSize(iDisOne);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());
            }
            return ds;
        }

        /// <summary>
        /// 通过iDisTwo ！=0 可以排除初始值
        /// </summary>
        /// <param name="iDisOne"></param>
        /// <param name="iDisTwo"></param>
        /// <returns></returns>
        public DataSet DataListTSysoptionSize(int iDisOne,int iDisTwo)
        {
            try
            {
                ds = Nova_DAL_TSysoption.DataListTSysoptionSize(iDisOne,iDisTwo);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());
            }
            return ds;
        }

        /// <summary>
        /// 获取品质状态视图
        /// </summary>
        /// <param name="strLaneID">巷道号</param>
        /// <returns></returns>
        public DataSet TSysoptionList(string strLaneID)
        {
            try
            {
                ds = Nova_DAL_TSysoption.TSysoptionList(strLaneID);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());
            }
            return ds;
        }

        ///<summary>
        ///获取货位存储类型信息表的状态颜色
        ///TSysoption表的存储类型的值是104,这个值是固定值
        ///</summary>
        ///<param name="sQL">SQL</param>
        ///<returns>返回dataset</returnss>
        ///Writer：[王成友]
        ///Create Date： [2010-7-8]
        ///</summary>
        public string getColor(int iDisOne, int N)
        {
            try
            {
                strColor = Nova_DAL_TSysoption.getColor(iDisOne, N);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());

            }
            return strColor;

        }

        /// <summary>
        /// 获取货位尺寸视图
        /// </summary>
        /// <param name="strProName">存储过程名字</param>
        /// <param name="strLaneID">巷道号</param>
        /// <returns></returns>
        public DataSet TSysoptionList_Size(string strProName, string strLaneID)
        {
            try
            {
                ds = Nova_DAL_TSysoption.TSysoptionList_Size(strProName, strLaneID);
            }
            catch (Exception ex)
            {
                Console.Write(ex.ToString());
            }
            return ds;
        }

        public DataSet SysOptionList_ABCKind(string strLaneID,int subArea)
        {
            return Nova_DAL_TSysoption.SysOptionList_ABCKind(strLaneID,subArea);
        }
    }
}
